/*
 * @Author: hanmengjie 515044692@qq.com
 * @Date: 2022-06-17 18:17:18
 * @LastEditors: hanmengjie 515044692@qq.com
 * @LastEditTime: 2022-06-19 15:28:06
 * @FilePath: \doctor-pc\doctor_end\src\service\activeService.js
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
import api from "@/api";
import axios from "@/utils/axios";

export default {
    getActiveList,
    addActiveBtn,
    searchActive
    
}
//获取诊疗活动列表
function getActiveList(page,size) {
    return axios({
        url: api.activeApi.getActiveList,
        headers:{
            "Content-Type":"application/x-www-form-urlencoded;charset=UTF-8"
        },
        method: 'post',
        params: {
            page,
            size,
        }
    })
}
//添加活动
function addActiveBtn(name,a_theme,a_target,a_liveTime,a_regTime,a_overTime,a_time,a_money,a_details) {
    return axios({
        url: api.activeApi.addActiveBtn,
        
        method: 'post',
        params: {
            name,a_theme,a_target,a_liveTime,a_regTime,a_overTime,a_time,a_money,a_details
        }
    })
}
//搜索活动
function searchActive(name,host,regTime,overTime,liveTime,isud,page,size) {
    return axios({
        url: api.activeApi.searchActive,
        
        method: 'post',
        params: {
            name,host,regTime,overTime,liveTime,isud,page,size
        }
    })
}
